function ind = get_ind(obj)

% ROME_VAR\GET_IND returns the indices of a diagonal rome_var object
%
%   ind = get_ind(obj);
%

% rome_var obj must be purely certain
assert(obj.IsCertain)

% retreive the biaffine map, disregard the first column (constant)
ind = obj.BiAffineMap(:,2:end)';

% each element of rome_var must correspond to only one primitive variable
assert(all(sum(ind ~= 0) == 1))

ind = obj.NumUnmappedVars + mod(find(ind)-1, size(ind,1))+1;
ind = reshape(ind, obj.Size);